package com.poten.mapper;
import com.poten.pojo.Order;
import org.apache.ibatis.annotations.*;

@Mapper
public interface OrderMapper {


    @Insert("insert into tb_order set oid=#{oid},name=#{name},price=#{price}," +
            "states=#{states},cretime=#{creTime}")
     void addOrder(Order order);


    @Select("select * from tb_order where oid=#{orderIdStr}")
    Order getById(@Param("orderIdStr") String orderIdStr);

    @Update("update tb_order set states=#{states} where oid=#{oid}")
    void updateByOId(Order order);

}
